﻿namespace SLClient.ServiceAPI
{
    using System;
    using System.CodeDom.Compiler;
    using System.ComponentModel;
    using System.Diagnostics;
    using System.Runtime.CompilerServices;
    using System.Runtime.Serialization;
    using System.Threading;

    [DataContract(Name="UserInfo", Namespace="http://schemas.datacontract.org/2004/07/SLClient"), GeneratedCode("System.Runtime.Serialization", "4.0.0.0"), DebuggerStepThrough]
    public class UserInfo : INotifyPropertyChanged
    {
        private decimal ActivityMoneyField;
        private DateTime CreateTimeField;
        private decimal FandianField;
        private bool FlagField;
        private decimal FreezeMoneyField;
        private bool? IsOnlineField;
        private DateTime? LastLoginTimeField;
        private int LoginCountField;
        private decimal MaxFiandianField;
        private string OnlineIpAddressField;
        private Guid? ParentIdField;
        private PropertyChangedEventHandler _PropertyChanged;
        private int? RoleIdField;
        private bool? StatusField;
        private decimal TotleMoneyField;
        private string UserAccountField;
        private Guid UserIdField;
        private string UserNickNameField;
        private string UserPwdField;
        private int? UserTypeField;

        public event PropertyChangedEventHandler PropertyChanged
        {
            add
            {
                PropertyChangedEventHandler handler2;
                PropertyChangedEventHandler propertyChanged = this._PropertyChanged;
                do
                {
                    handler2 = propertyChanged;
                    PropertyChangedEventHandler handler3 = (PropertyChangedEventHandler) Delegate.Combine(handler2, value);
                    propertyChanged = Interlocked.CompareExchange<PropertyChangedEventHandler>(ref this._PropertyChanged, handler3, handler2);
                }
                while (propertyChanged != handler2);
            }
            remove
            {
                PropertyChangedEventHandler handler2;
                PropertyChangedEventHandler propertyChanged = this._PropertyChanged;
                do
                {
                    handler2 = propertyChanged;
                    PropertyChangedEventHandler handler3 = (PropertyChangedEventHandler) Delegate.Remove(handler2, value);
                    propertyChanged = Interlocked.CompareExchange<PropertyChangedEventHandler>(ref this._PropertyChanged, handler3, handler2);
                }
                while (propertyChanged != handler2);
            }
        }

        protected void RaisePropertyChanged(string propertyName)
        {
            PropertyChangedEventHandler propertyChanged = this._PropertyChanged;
            if (propertyChanged != null)
            {
                propertyChanged(this, new PropertyChangedEventArgs(propertyName));
            }
        }

        [DataMember(Order=9)]
        public decimal ActivityMoney
        {
            get
            {
                return this.ActivityMoneyField;
            }
            set
            {
                if (!this.ActivityMoneyField.Equals(value))
                {
                    this.ActivityMoneyField = value;
                    this.RaisePropertyChanged("ActivityMoney");
                }
            }
        }

        [DataMember(Order=11)]
        public DateTime CreateTime
        {
            get
            {
                return this.CreateTimeField;
            }
            set
            {
                if (!this.CreateTimeField.Equals(value))
                {
                    this.CreateTimeField = value;
                    this.RaisePropertyChanged("CreateTime");
                }
            }
        }

        [DataMember(Order=14)]
        public decimal Fandian
        {
            get
            {
                return this.FandianField;
            }
            set
            {
                if (!this.FandianField.Equals(value))
                {
                    this.FandianField = value;
                    this.RaisePropertyChanged("Fandian");
                }
            }
        }

        [DataMember(Order=0x12)]
        public bool Flag
        {
            get
            {
                return this.FlagField;
            }
            set
            {
                if (!this.FlagField.Equals(value))
                {
                    this.FlagField = value;
                    this.RaisePropertyChanged("Flag");
                }
            }
        }

        [DataMember(Order=10)]
        public decimal FreezeMoney
        {
            get
            {
                return this.FreezeMoneyField;
            }
            set
            {
                if (!this.FreezeMoneyField.Equals(value))
                {
                    this.FreezeMoneyField = value;
                    this.RaisePropertyChanged("FreezeMoney");
                }
            }
        }

        [DataMember(Order=6)]
        public bool? IsOnline
        {
            get
            {
                return this.IsOnlineField;
            }
            set
            {
                if (!this.IsOnlineField.Equals(value))
                {
                    this.IsOnlineField = value;
                    this.RaisePropertyChanged("IsOnline");
                }
            }
        }

        [DataMember(Order=12)]
        public DateTime? LastLoginTime
        {
            get
            {
                return this.LastLoginTimeField;
            }
            set
            {
                if (!this.LastLoginTimeField.Equals(value))
                {
                    this.LastLoginTimeField = value;
                    this.RaisePropertyChanged("LastLoginTime");
                }
            }
        }

        [DataMember(Order=0x11)]
        public int LoginCount
        {
            get
            {
                return this.LoginCountField;
            }
            set
            {
                if (!this.LoginCountField.Equals(value))
                {
                    this.LoginCountField = value;
                    this.RaisePropertyChanged("LoginCount");
                }
            }
        }

        [DataMember(Order=15)]
        public decimal MaxFiandian
        {
            get
            {
                return this.MaxFiandianField;
            }
            set
            {
                if (!this.MaxFiandianField.Equals(value))
                {
                    this.MaxFiandianField = value;
                    this.RaisePropertyChanged("MaxFiandian");
                }
            }
        }

        [DataMember(Order=13)]
        public string OnlineIpAddress
        {
            get
            {
                return this.OnlineIpAddressField;
            }
            set
            {
                if (!object.ReferenceEquals(this.OnlineIpAddressField, value))
                {
                    this.OnlineIpAddressField = value;
                    this.RaisePropertyChanged("OnlineIpAddress");
                }
            }
        }

        [DataMember(Order=7)]
        public Guid? ParentId
        {
            get
            {
                return this.ParentIdField;
            }
            set
            {
                if (!this.ParentIdField.Equals(value))
                {
                    this.ParentIdField = value;
                    this.RaisePropertyChanged("ParentId");
                }
            }
        }

        [DataMember(Order=8)]
        public int? RoleId
        {
            get
            {
                return this.RoleIdField;
            }
            set
            {
                if (!this.RoleIdField.Equals(value))
                {
                    this.RoleIdField = value;
                    this.RaisePropertyChanged("RoleId");
                }
            }
        }

        [DataMember(Order=0x10)]
        public bool? Status
        {
            get
            {
                return this.StatusField;
            }
            set
            {
                if (!this.StatusField.Equals(value))
                {
                    this.StatusField = value;
                    this.RaisePropertyChanged("Status");
                }
            }
        }

        public int Tag { get; set; }

        [DataMember]
        public decimal TotleMoney
        {
            get
            {
                return this.TotleMoneyField;
            }
            set
            {
                if (!this.TotleMoneyField.Equals(value))
                {
                    this.TotleMoneyField = value;
                    this.RaisePropertyChanged("TotleMoney");
                }
            }
        }

        [DataMember(Order=2)]
        public string UserAccount
        {
            get
            {
                return this.UserAccountField;
            }
            set
            {
                if (!object.ReferenceEquals(this.UserAccountField, value))
                {
                    this.UserAccountField = value;
                    this.RaisePropertyChanged("UserAccount");
                }
            }
        }

        [DataMember]
        public Guid UserId
        {
            get
            {
                return this.UserIdField;
            }
            set
            {
                if (!this.UserIdField.Equals(value))
                {
                    this.UserIdField = value;
                    this.RaisePropertyChanged("UserId");
                }
            }
        }

        [DataMember(Order=5)]
        public string UserNickName
        {
            get
            {
                return this.UserNickNameField;
            }
            set
            {
                if (!object.ReferenceEquals(this.UserNickNameField, value))
                {
                    this.UserNickNameField = value;
                    this.RaisePropertyChanged("UserNickName");
                }
            }
        }

        [DataMember(Order=3)]
        public string UserPwd
        {
            get
            {
                return this.UserPwdField;
            }
            set
            {
                if (!object.ReferenceEquals(this.UserPwdField, value))
                {
                    this.UserPwdField = value;
                    this.RaisePropertyChanged("UserPwd");
                }
            }
        }

        [DataMember(Order=4)]
        public int? UserType
        {
            get
            {
                return this.UserTypeField;
            }
            set
            {
                if (!this.UserTypeField.Equals(value))
                {
                    this.UserTypeField = value;
                    this.RaisePropertyChanged("UserType");
                }
            }
        }
    }
}

